Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bpf: allow setting mount device for bpffs #2338

Closed
wants to merge 2 commits into from

Conversation

kernel-patches-bot
Copy link

Pull request for series with
subject: bpf: allow setting mount device for bpffs
version: 1
url: https://patchwork.kernel.org/project/netdevbpf/list/?series=601389

@kernel-patches-bot
Copy link
Author

Master branch: ecf45e6
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=601389
version: 1

@kernel-patches-bot
Copy link
Author

Master branch: f60edf5
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=601389
version: 1

@kernel-patches-bot
Copy link
Author

Master branch: 5b3d729
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=601389
version: 1

@kernel-patches-bot
Copy link
Author

Master branch: b645941
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=601389
version: 1

@kernel-patches-bot
Copy link
Author

Master branch: 3ccdcee
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=601389
version: 1

@kernel-patches-bot
Copy link
Author

Master branch: 1705c62
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=601389
version: 1

@kernel-patches-bot
Copy link
Author

Master branch: 35580f9
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=601389
version: 1

@kernel-patches-bot
Copy link
Author

Master branch: 35580f9
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=601389
version: 1

@kernel-patches-bot
Copy link
Author

Master branch: 63d000c
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=601389
version: 1

@kernel-patches-bot
Copy link
Author

Master branch: 11f9983
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=601389
version: 1

@kernel-patches-bot
Copy link
Author

Master branch: 9e6b19a
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=601389
version: 1

@kernel-patches-bot
Copy link
Author

Master branch: e63a023
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=601389
version: 1

@kernel-patches-bot
Copy link
Author

Master branch: 5e22dd1
series: https://patchwork.kernel.org/project/netdevbpf/list/?series=601389
version: 1

We noticed our tc ebpf tools can't start after we upgrade our in-house
kernel version from 4.19 to 5.10. That is because of the behaviour change
in bpffs caused by commit
d2935de ("vfs: Convert bpf to use the new mount API").

In our tc ebpf tools, we do strict environment check. If the enrioment is
not match, we won't allow to start the ebpf progs. One of the check is
whether bpffs is properly mounted. The mount information of bpffs in
kernel-4.19 and kernel-5.10 are as follows,

- kenrel 4.19
$ mount -t bpf bpffs /sys/fs/bpf
$ mount -t bpf
bpffs on /sys/fs/bpf type bpf (rw,relatime)

- kernel 5.10
$ mount -t bpf bpffs /sys/fs/bpf
$ mount -t bpf
none on /sys/fs/bpf type bpf (rw,relatime)

The device name in kernel-5.10 is displayed as none instead of bpffs,
then our environment check fails. Currently we modify the tools to adopt to
the kernel behaviour change, but I think we'd better change the kernel code
to keep the behavior consistent.

After this change, the mount information will be displayed the same with
the behavior in kernel-4.19, for example,

$ mount -t bpf bpffs /sys/fs/bpf
$ mount -t bpf
bpffs on /sys/fs/bpf type bpf (rw,relatime)

Fixes: d2935de ("vfs: Convert bpf to use the new mount API")
Signed-off-by: Yafang Shao <laoar.shao@gmail.com>
Cc: David Howells <dhowells@redhat.com>
@kernel-patches-bot
Copy link
Author

At least one diff in series https://patchwork.kernel.org/project/netdevbpf/list/?series=601389 expired. Closing PR.

@kernel-patches-bot kernel-patches-bot deleted the series/601389=>bpf-next branch January 7, 2022 21:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants